<?php

namespace app\index\validate;

use think\Request;
use think\Validate;
use think\Exception;

class basicValidate extends Validate
{
    /** 获取http传入的参数,对这些参数做校验
     * @return bool
     */
    public function goCheck()
    {
        //获取http传入的参数
        // 对这些参数做校验
        $request = Request::instance();
        $params = $request->param();

        $result = $this->check($params);
        if (!$result){
            $error = $this->getError();
            return $error;
        }else{
            return true;
        }
    }


}